﻿@using Hx.DataTransferObject
@{
    ViewBag.Title = "札记";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
<div class="indexPage">
    @foreach (CategoryObject category in ViewBag.Categorys)
    {
        <div class="forumn">
            <div class="title">@category.Title</div>
            @if (category.Children != null && category.Children.Count > 0)
            {
                <div class="subs">
                    @foreach (var sub in category.Children)
                    {
                        <div class="sub">
                            <div class="subtitle">
                                @Html.RouteLink(sub.Title, "Category", new { category = sub.Id })
                            </div>
                            <div class="subcontent">
                                札记<span class="num">@sub.ArticleCount</span>篇，最新文章：
                            </div>
                        </div>
                    }
                </div>
            }
        </div>
}
</div>
